home *** CD-ROM | disk | FTP | other *** search
/ BBS in a Box 11 / AMUG BBS in a Box Volume XI (April 1994) (MacWizards).iso / Files / Prog / D-G / Generic init.sit / Generic init / generic init docs next >
Encoding:
Text File  |  1993-05-23  |  1.4 KB  |  35 lines  |  [TEXT/ttxt]

  1. BE WARNED - used as is this init will put up an alert every
  2. ten seconds until you hold down the command key while dismissing
  3. the alert.
  4.  
  5. This is a generic timed init that makes use of the Time
  6. Manager and the Notification Manager.  It uses both in this
  7. way:
  8.  
  9. 1) It queues up a delayed call to the Time Manager.
  10.  
  11. 2) Because the Time Manager is called at interrupt time and
  12. we want to perform a task which involves moving memory (not 
  13. allowed at interrupt time) the only thing our call does is
  14. to queue up a call to the Notification Manager, which will 
  15. execute during GetNextEvent/WaitNextEvent time, allowing us
  16. to do what we will.
  17.  
  18. 3) When we have completed our task (through using the response
  19. routine allowed in a Notification record), we queue up another
  20. call to the Time Manager which, when executed, will queue up
  21. the same Notification record, which at its end calls the Time
  22. Manager - etc.etc.etc.
  23.  
  24. BE WARNED - used as is this init will put up an alert every
  25. ten seconds until you hold down the command key while dismissing
  26. the alert.
  27.  
  28.  
  29. This was my first init and I'm trying to save folks the hell
  30. I went through in figuring it out.  I'm sure there are ways
  31. to optimize the code and if anyone can make improvements,
  32. in the code or in the commented documentation please do so 
  33. and pass them on.  Lord knows there is a dearth of info about
  34. the structure and execution of inits.
  35.